import com.peng.Service.UserServiceImp;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class MytestSpring {
    public static void main(String[] args) {
        ApplicationContext context = new ClassPathXmlApplicationContext("beans.xml");
        UserServiceImp UserServiceImp = (UserServiceImp)context.getBean("UserServiceImp");
        UserServiceImp.getUser();
    }
}
